package com.face.server.exception;

/**
 * Created by ryan on 2018/1/25.
 */
public class ExException extends RuntimeException{
    private Integer code;

    public ExException(ResultEnum resultEnum) {
        super(resultEnum.getMsg());//RuntimeException中有msg属性 这里可以重写他
        this.code=resultEnum.getCode();
    }

    public ExException(Integer code,String msg) {
        super(msg);//重写msg
        this.code=code;
    }

}